home *** CD-ROM | disk | FTP | other *** search
/ Aminet 31 / Aminet 31 (1999)(Schatztruhe)[!][Jun 1999].iso / Aminet / dev / cross / z88dk_v1.0s.lha / src / cpp / cppdef.h < prev   
Encoding:
C/C++ Source or Header  |  1998-08-12  |  4.0 KB  |  150 lines

  1. #define    TRUE            1
  2. #define    FALSE            0
  3.  
  4. #define    SYS_UNKNOWN        0
  5. #define    SYS_UNIX        1
  6. #define    SYS_VMS            2
  7. #define    SYS_RSX            3
  8. #define    SYS_RT11        4
  9. #define    SYS_LATTICE        5
  10. #define    SYS_ONYX        6
  11. #define    SYS_68000        7
  12.  
  13. #define HOST            SYS_UNIX
  14. #define TARGET            SYS_UNIX
  15. #define LINE_PREFIX        ""
  16. #define MSG_PREFIX        "cpp: "
  17. #define FILE_LOCAL
  18. #define OK_DOLLAR        FALSE
  19. #define OK_CONCAT        TRUE
  20.  
  21. /*
  22.  * RECURSION_LIMIT may be set to -1 to disable the macro recursion test.
  23.  */
  24. #ifndef    RECURSION_LIMIT
  25. #define    RECURSION_LIMIT    1000
  26. #endif
  27.  
  28. /*
  29.  * BITS_CHAR may be defined to set the number of bits per character.
  30.  * it is needed only for multi-byte character constants.
  31.  */
  32. #ifndef    BITS_CHAR
  33. #define    BITS_CHAR        8
  34. #endif
  35.  
  36. /*
  37.  * BIG_ENDIAN is set TRUE on machines (such as the IBM 360 series)
  38.  * where 'ab' stores 'a' in the high-bits and 'b' in the low-bits.
  39.  * It is set FALSE on machines (such as the PDP-11 and Vax-11)
  40.  * where 'ab' stores 'a' in the low-bits and 'b' in the high-bits.
  41.  * (Or is it the other way around?) -- Warning: BIG_ENDIAN code is untested.
  42.  */
  43. #ifndef    BIG_ENDIAN
  44. #define    BIG_ENDIAN         FALSE
  45. #endif
  46.  
  47. /*
  48.  * COMMENT_INVISIBLE may be defined to allow "old-style" comment
  49.  * processing, whereby the comment becomes a zero-length token
  50.  * delimiter.  This permitted tokens to be concatenated in macro
  51.  * expansions.  This was removed from the Draft Ansi Standard.
  52.  */
  53. #ifndef    COMMENT_INVISIBLE
  54. #define    COMMENT_INVISIBLE    FALSE
  55. #endif
  56.  
  57. /*
  58.  * STRING_FORMAL may be defined to allow recognition of macro parameters
  59.  * anywhere in replacement strings.  This was removed from the Draft Ansi
  60.  * Standard and a limited recognition capability added.
  61.  */
  62. #ifndef    STRING_FORMAL
  63. #define    STRING_FORMAL        FALSE
  64. #endif
  65.  
  66. /*
  67.  * OK_DOLLAR enables use of $ as a valid "letter" in identifiers.
  68.  * This is a permitted extension to the Ansi Standard and is required
  69.  * for e.g., VMS, RSX-11M, etc.   It should be set FALSE if cpp is
  70.  * used to preprocess assembler source on Unix systems.  OLD_PREPROCESSOR
  71.  * sets OK_DOLLAR FALSE for that reason.
  72.  */
  73. #ifndef    OK_DOLLAR
  74. #define    OK_DOLLAR        TRUE
  75. #endif
  76.  
  77. /*
  78.  * OK_CONCAT enables (one possible implementation of) token concatenation.
  79.  * If cpp is used to preprocess Unix assembler source, this should be
  80.  * set FALSE as the concatenation character, #, is used by the assembler.
  81.  */
  82. #ifndef    OK_CONCAT
  83. #define    OK_CONCAT        TRUE
  84. #endif
  85.  
  86. /*
  87.  * OK_DATE may be enabled to predefine today's date as a string
  88.  * at the start of each compilation.  This is apparently not permitted
  89.  * by the Draft Ansi Standard.
  90.  */
  91. #ifndef    OK_DATE
  92. #define    OK_DATE        TRUE
  93. #endif
  94.  
  95. /*
  96.  * Some common definitions.
  97.  */
  98.  
  99. #ifndef    DEBUG
  100. #define    DEBUG            FALSE
  101. #endif
  102.  
  103. /*
  104.  * The following definitions are used to allocate memory for
  105.  * work buffers.  In general, they should not be modified
  106.  * by implementors.
  107.  *
  108.  * PAR_MAC    The maximum number of #define parameters (31 per Standard)
  109.  *        Note: we need another one for strings.
  110.  * IDMAX    The longest identifier, 31 per Ansi Standard
  111.  * NBUFF    Input buffer size
  112.  * NWORK    Work buffer size -- the longest macro
  113.  *        must fit here after expansion.
  114.  * NEXP        The nesting depth of #if expressions
  115.  * NINCLUDE    The number of directories that may be specified
  116.  *        on a per-system basis, or by the -I option.
  117.  * BLK_NEST    The number of nested #if's permitted.
  118.  */
  119.  
  120. #ifndef IDMAX
  121. #define    IDMAX             31
  122. #endif
  123. #define    PAR_MAC           (31 + 1)
  124. #define    NBUFF            4096
  125. #define    NWORK            4096
  126. #define    NEXP            128
  127. #define    NINCLUDE          7
  128. #define    NPARMWORK        (NWORK * 2)
  129. #define    BLK_NEST        32
  130.  
  131. /*
  132.  * Some special constants.  These may need to be changed if cpp
  133.  * is ported to a wierd machine.
  134.  *
  135.  * NOTE: if cpp is run on a non-ascii machine, ALERT and VT may
  136.  * need to be changed.  They are used to implement the proposed
  137.  * ANSI standard C control characters '\a' and '\v' only.
  138.  * DEL is used to tag macro tokens to prevent #define foo foo
  139.  * from looping.  Note that we don't try to prevent more elaborate
  140.  * #define loops from occurring.
  141.  */
  142.  
  143. #ifndef    ALERT
  144. #define    ALERT            '\007'        /* '\a' is "Bell"    */
  145. #endif
  146.  
  147. #ifndef    VT
  148. #define    VT            '\013'        /* Vertical Tab CTRL/K    */
  149. #endif
  150.